//
//  MacAppTarget.m
//  iCodeMac
//
//  Created by Andrew Barry on 27/04/09.
//  Copyright 2009 __MyCompanyName__. All rights reserved.
//

#import "MacAppTarget.h"
#import "Debugger.h"
#import "JavascriptProject.h"

static MacAppTarget *gSharedInstance;

@implementation MacAppTarget
+(id<CodeTarget>) sharedInstance {
	if (!gSharedInstance)
		gSharedInstance = [MacAppTarget new];
	return gSharedInstance;
}

-(void) run: (JavascriptProject *) project {
	if (![project buildApplicationForRelease: false])
		return;
	NSString *path = [project buildPath];
	[[DebugLauncher sharedLauncher] launch:path];
}
@end
